﻿<Window x:Class="Power.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="热力系统管理软件" Height="398" Width="840" Loaded="Window_Loaded" WindowState="Maximized">
    <Grid>
        <DockPanel>
            <Menu Height="23" DockPanel.Dock="Top" Name="menu1">
                <MenuItem Header="系统">
                    <MenuItem Header="修改密码" Click="MenuItem_Click_1"></MenuItem>

                    <MenuItem Header="退出" Click="MenuItem_Click"></MenuItem>
                </MenuItem>

                <MenuItem Header="用户">
                    <MenuItem Header="添加" Name="btnad" Click="btnAdd_Click"></MenuItem>

                    <MenuItem Header="编辑" Name="btned" Click="btnEdit_Click"></MenuItem>
                    <MenuItem Header="进行报修" Name="btnrp" Click="btnPrere_Click"></MenuItem>

                    <MenuItem Header="完成维修记录" Name="btnfnrp" Click="btnAftre_Click"></MenuItem>

                    <MenuItem Header="显示记录" Name="btnlsrp"  Click="btnRepr_Click"></MenuItem>

                    <MenuItem Header="显示报修用户" Name="btnlscus" Click="btnRPDS_Click"></MenuItem>

                </MenuItem>
                <MenuItem Header="温度">
                    <MenuItem Header="显示选定用户数据" Name="listthis" Click="Mon_Click"></MenuItem>

                    <MenuItem Header="显示异常用户" Name="finderr" Click="MenuItem_Click_2"></MenuItem>
                </MenuItem>

                <MenuItem Header="关于" Click="MenuItem_Click_3"></MenuItem>
            </Menu>
            <ToolBar DockPanel.Dock="Top" Height="35">

                <Button Name="btnAdd" ToolTip="新增" Click="btnAdd_Click">

                    <Image Source="Images/add.ico" ></Image>
                </Button>
                <Button Name="btnMin" ToolTip="删除" Click="btnMin_Click">

                    <Image Source="Images/minus.png" ></Image>
                </Button>

                <Button Name="btnEdit" ToolTip="编辑" Click="btnEdit_Click">

                    <Image Source="Images/edit.png" ></Image>
                </Button>

                <Label Content="查询：" FontSize="16"></Label>
                <TextBox Width="200" Name="Findbox"></TextBox>

                <Button Name="btnfind" Click="Button_Click">
                    <Image Source="/Images/find.png"></Image>
                </Button>

            </ToolBar>

            <DataGrid AutoGenerateColumns="False" Name="dg1" IsReadOnly="True">
                <DataGrid.Columns>
                    <DataGridTextColumn Header="客户名" Width="100" Binding="{Binding CusName}"></DataGridTextColumn>

                    <DataGridTextColumn Header="地址" Width="160" Binding="{Binding Address}" ></DataGridTextColumn>
                    <DataGridTextColumn Header="电话" Width="100" Binding="{Binding Phone}"></DataGridTextColumn>
                    <DataGridTextColumn Header="身份证号" Width="120" Binding="{Binding CID}" ></DataGridTextColumn>
                    <DataGridTextColumn Header="设备号" Width="120" Binding="{Binding Device}" ></DataGridTextColumn>

                </DataGrid.Columns>

            </DataGrid>
        </DockPanel>
    </Grid>
</Window>